using System;
using System.Collections.Generic;
using System.Text;

namespace WinXnaFE
{
    public class Timer
    {
        double currentDelay;
        double targetTime;
        public Timer(double targetTime)
        {
            this.targetTime = targetTime;
        }
        public void Update(double elapsedTime)
        {
            currentDelay += elapsedTime;
        }
        public bool Ready
        {
            get
            {
                if (currentDelay >= targetTime)
                {
                    currentDelay = 0;
                    return true;
                }
                return false;
            }
        }
    }
}
